package com.code.day19;

import java.util.ArrayList;

public class Demo11List {
    public static void main(String[] args) {
        ArrayList<String> list1 = new ArrayList<>();
        list1.add("张三");
        list1.add("李四");
        list1.add("王五");
        ArrayList<String> list2 = new ArrayList<>();
        list2.add("赵六");
        list2.add("钱七");
        list2.add("孙八");

        ArrayList<ArrayList<String>> list = new ArrayList<>();
        list.add(list1);
        list.add(list2);

        for (ArrayList<String> arrayList : list) {
            for (String s : arrayList) {
                System.out.println(s);
            }
        }

    }
}
